#ifndef _DISPLAY_H
#define _DISPLAY_H

#include "r_cg_macrodriver.h"



#define DISPLAY_DRIVER_DIG1    (P6_bit.no0)
#define DISPLAY_DRIVER_DIG2    (P6_bit.no1)

#define SEG1    (P1_bit.no3)
#define SEG2    (P5_bit.no0)
#define SEG3    (P5_bit.no1)
#define SEG4    (P1_bit.no6)
#define SEG5    (P1_bit.no7)
#define SEG6    (P1_bit.no4)
#define SEG7    (P1_bit.no5)
#define SEG8    (P7_bit.no0)
#define SEG9    (P3_bit.no0)
#define SEG10   (P3_bit.no1)
#define SEG11   (P12_bit.no0)
#define SEG12   (P14_bit.no7)


extern uint8_t led_seg_out[2];

void rinnai_delay_us(uint8_t cnt);
void display_all(void);
void display_clean(void);
void DisplayDriverClear(void);
void DisplaySegClear(void);
void display_process(void);
void led_scan_dig(uint8_t dig);
//void led_scan_seg(uint8_t segment);
void led_scan_seg(uint8_t segment,uint8_t segment_1);
void display_run(uint8_t temp, uint8_t eco_code,uint8_t fire_code,uint8_t cricle,uint8_t pressure);
void display_version(uint8_t temp1, uint8_t temp2,uint8_t eco_code,uint8_t fire_code,uint8_t cricle,uint8_t pressure);
void display_err_fire(uint8_t err_code,uint8_t err_code_l,uint8_t err_eco_code,uint8_t err_fire_code,uint8_t cricle,uint8_t pressure);
void display_err_action(uint8_t ac_code,uint8_t ac_code_l,uint8_t ac_eco_code,uint8_t ac_fire_code,uint8_t ac_cricle,uint8_t ac_pressure);
void err_display_clean(uint8_t clean_eco_code,uint8_t clean_fire_code,uint8_t cricle,uint8_t pressure);
void display_pressure(uint8_t pressure);
void display_cricle(uint8_t cricle);

void display_wifi(uint8_t icon);

#endif